"""

"""


def print_matrix(row, col):
    start = 0
    end = 0
    matrix = []
    for i in range(col):
        end += row
        col_list = list(range(start + 1, end + 1))
        start = end
        if i % 2:
            col_list.reverse()

        matrix.append(col_list)

    for i in range(row):
        sub_list = []
        for j in range(col):
            sub_list.append(matrix[j][i])
        print(sub_list)


print_matrix(3, 5)
